Dyeing fabric containing cellulosic fibers is an important chemical industrial process that results in multiple commercial textile products. Dyeing is the most costly step in the textile processing. A typical dyeing protocol involves the use of high amount of water and energy and generates significant amount of chemical waste. Further, when contacted with water, cellulosic fibers generate slightly negative charges due to ionization of the hydroxyl groups. This reduces the efficiency of dyeing cellulosic fibers due to the fact that many dye molecules (including the reactive dyes) contain a negatively charged anionic group (e.g., CO2H or SO2H). To overcome this, in a conventional dyeing process, a large amount of electrolytes, such as Glauber's salt, is used to neutralize the repulsive forces between negative charges of the dye and negative charges produced on the fiber surface. When Glauber's salt is used, approximately 60% of the dye is exhausted in conventional dyeing systems. The electrolyte remaining in the dyebath after dyeing pollutes the environment via the discharge of a highly colored and saline dyebath. Further, the abundant hydroxyl ions typically cause significant hydrolysis of the reactive dyes.